Skip to content

[HLSL Options] Remove select-validator option#7423

Merged
bob80905 merged 4 commits intomicrosoft:mainfrom
bob80905:remove_select_validator_option_obsolete
May 8, 2025
Merged

[HLSL Options] Remove select-validator option#7423
bob80905 merged 4 commits intomicrosoft:mainfrom
bob80905:remove_select_validator_option_obsolete

Conversation

@bob80905
Copy link
Copy Markdown
Collaborator

@bob80905 bob80905 commented May 2, 2025

This PR removes the select-validator option. It is being deprecated, and it wasn't ever officially documented.
Fixes #7419

Copy link
Copy Markdown
Contributor

@tex3d tex3d left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need a way to update tests with an option to prevent downlevel validator testing. Some of these tests should be revisited more carefully for their intended purpose after adding the external validator path option and global environment variable override.

// CHECK-NOT: error

// RUN: %dxc -T vs_6_8 -select-validator internal %s | FileCheck %s
// RUN: %dxc -T vs_6_8 %s | FileCheck %s
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This now matches the first RUN line, so it seems to be pointless.
This test should probably be re-thought-through since the assumptions in the comments are now out of date.

Copy link
Copy Markdown
Collaborator Author

@bob80905 bob80905 May 8, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Understood, removed that Run Line. Cleaned up the comments too.
Fully intend to use the proposed dxil_dll_path option to augment these tests when I get around to that in a separate PR.

Copy link
Copy Markdown
Contributor

@tex3d tex3d left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The option test needs to be moved under the DXC path instead of Parser.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just realized that this is in the wrong location. This is a folder of clang c/cpp parser tests, not for testing the argument parsing. This whole folder is disabled for the DXC project, so this test will not run.

Check lit.local.cfg under Parser for:

config.suffixes = [] # HLSL Change - Disable lit suites.

This should be moved under the DXC folder instead.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done!

@github-project-automation github-project-automation Bot moved this from New to In progress in HLSL Roadmap May 8, 2025
Copy link
Copy Markdown
Collaborator

@pow2clk pow2clk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a suggestion, but you can take or leave it.

// Test that the deprecated option, select-validator, doesn't work.
// RUN: not %dxc -E main -T vs_6_7 -select-validator internal %s 2>&1 | FileCheck %s

// CHECK: dxc failed : Unknown argument: '-select-validator'
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wasn't going to suggest we might include a bespoke error message since the option was hidden all along. For some reason, this test makes me think to at least mention the possibility of a warning that the flag is ignored and a mention of the replacement environment variable. I don't mind either way.

@bob80905 bob80905 merged commit 422604b into microsoft:main May 8, 2025
12 checks passed
@github-project-automation github-project-automation Bot moved this from In progress to Done in HLSL Roadmap May 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

[HLSLOptions] Deprecate -select-validator option

3 participants